/*
 * events_sender.hpp
 *
 *  Created on: 04.05.2011
 *      Author: inkooboo
 */

#ifndef _SYSTEMS_EVENTS_SENDER_HPP_
# define _SYSTEMS_EVENTS_SENDER_HPP_

# include "system.hpp"
# include "core/event.hpp"
# include "net/mock_client.hpp"

# include <boost/shared_ptr.hpp>
# include <boost/noncopyable.hpp>

class events_sender_t : private boost::noncopyable, public if_system_t
{
public:

    static boost::shared_ptr<if_system_t> create(f_engine_t *engine);

    void start(); /*override*/

    void send(const event_t &event);

private:
    events_sender_t(f_engine_t *engine) :
        engine_(engine)
    {
    }

    tcp_client_t client_;

    f_engine_t *engine_;
};



#endif /* _SYSTEMS_EVENTS_SENDER_HPP_ */
